package com.guiyang.practice.mess1.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import java.util.Date;

public class MessageRecord {
    private Long id;
    private String title;
    private String content;
    private String messageType;
    private Long senderId;
    private String senderName;
    private Integer receiverType;
    private String receiverIds;
    private Integer status;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date sendTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    // 关联查询字段
    private String typeName;

    // Getter 和 Setter 方法
    public Long getId() { return id; }
    public void setId(Long id) { this.id = id; }

    public String getTitle() { return title; }
    public void setTitle(String title) { this.title = title; }

    public String getContent() { return content; }
    public void setContent(String content) { this.content = content; }

    public String getMessageType() { return messageType; }
    public void setMessageType(String messageType) { this.messageType = messageType; }

    public Long getSenderId() { return senderId; }
    public void setSenderId(Long senderId) { this.senderId = senderId; }

    public String getSenderName() { return senderName; }
    public void setSenderName(String senderName) { this.senderName = senderName; }

    public Integer getReceiverType() { return receiverType; }
    public void setReceiverType(Integer receiverType) { this.receiverType = receiverType; }

    public String getReceiverIds() { return receiverIds; }
    public void setReceiverIds(String receiverIds) { this.receiverIds = receiverIds; }

    public Integer getStatus() { return status; }
    public void setStatus(Integer status) { this.status = status; }

    public Date getSendTime() { return sendTime; }
    public void setSendTime(Date sendTime) { this.sendTime = sendTime; }

    public Date getCreateTime() { return createTime; }
    public void setCreateTime(Date createTime) { this.createTime = createTime; }

    public String getTypeName() { return typeName; }
    public void setTypeName(String typeName) { this.typeName = typeName; }

    @Override
    public String toString() {
        return "MessageRecord{" +
                "id=" + id +
                ", title='" + title + '\'' +
                ", content='" + content + '\'' +
                ", messageType='" + messageType + '\'' +
                ", senderId=" + senderId +
                ", senderName='" + senderName + '\'' +
                ", receiverType=" + receiverType +
                ", receiverIds='" + receiverIds + '\'' +
                ", status=" + status +
                ", sendTime=" + sendTime +
                ", createTime=" + createTime +
                ", typeName='" + typeName + '\'' +
                '}';
    }
}